package ex103;

public class PositiveInteger {
    int value;

    public int sumOfDigits() {
        int result = 0, n = value;
        while (n != 0) {
            result += n % 10;
            n /= 10;
        }
        return result;
    }
}
